contract::class_view: nav_is_fully_connected requires reached == screens (codex P2 follow-up to #670)#673
Conversation
…ens (codex P2 #670) Follow-up to the merged #670. nav_is_fully_connected first shipped as screens ⊆ reached (every declared screen reachable from root). Codex P2 caught that the subset test passes two cases a level-editor validator must reject: - dangling click: an edge whose target is NOT a declared screen — screens={0,1} with 1->99 passed despite the dead link to 99, because every *declared* screen was still reachable; - unserved root: root not among the declared screens — screens={1}, root=0, 0->1 passed even though the entry screen isn't served. Strengthen to exact equality: screens_reachable_from(root, edges) == screens. That single check subsumes all three modes — orphan (screens ⊆ reached), dangling (reached ⊆ screens), and unserved root (reached always contains root, so root ∉ screens forces inequality). Cycles still allowed (reachability, not acyclicity). +2 regression tests; the original 3 pass unchanged. class_view 35/35, clippy -D warnings clean. Board: EPIPHANIES E-KLICKWEG-2 correction. Co-Authored-By: Claude Opus 4.8 <[email protected]>
|
Warning Review limit reached
Next review available in: 21 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_8b199cd8-d733-495f-bbcd-d88392aa8e1e) |
Follow-up to the merged #670, addressing the unresolved codex P2 review comment on it (
nav_is_fully_connectedwas too permissive).The gap codex caught
nav_is_fully_connectedshipped asscreens ⊆ reached— "every declared screen is reachable from root". That subset test passes two cases a "every pipe leads somewhere" validator must reject:screens={0,1}, edge1→99passed despite the dead link to99, because every declared screen was still reachable.root ∉ screens.screens={1},root=0,0→1passed even though the entry screen isn't served.The fix (one line, strictly stronger)
Exact equality subsumes all three failure modes at once:
screens ⊆ reached(declared screen unreachable);reached ⊆ screens(reached target undeclared);reachedalways containsroot, soroot ∉ screens⟹ inequality.Cycles remain allowed (this is reachability, not acyclicity — back-navigation is legal).
Tests
+2 regression tests (
nav_dangling_click_fails_connectivity,nav_unserved_root_fails_connectivity) reproducing codex's exact examples. The original 3 nav tests pass unchanged — their reached set already equalled the declared universe.class_view35/35, clippy-D warningsclean.Board
EPIPHANIES
E-KLICKWEG-2(correction toE-KLICKWEG-1).🤖 Generated with Claude Code
Generated by Claude Code